import { createHash } from "crypto"

export const md5 = (str: string) => createHash("md5").update(str).digest("hex")
export const sha1 = (str: string) => createHash("sha1").update(str).digest("hex")
export const cryptoPassword = (password: string) => md5(sha1(password))
export const create_uid = (info: string[]) => md5(sha1(`${Math.random()}_${Date.now()}_${info.join(",")}`));
